package com.brillilab.domain.enums.file;

import lombok.AllArgsConstructor;
import lombok.Getter;

/**
 * @author zlb
 * @Title: 文件类型
 * @ProjectName brill_lab
 * @Description: TODO
 * @date 2019/9/5 18:19
 */
@Getter
@AllArgsConstructor
public enum FileTypeEnum {
    File("文件",0),
    Audio("音频",1),
    Video("视频",2),
    Image("图片",3);
    public String name;
    private Integer value;

    public static String getKey(Integer value) {
        for (UploadStausEnum p : UploadStausEnum.values()) {
            if (p.getValue().equals(value)) {
                return p.name;
            }
        }
        return null;
    }
}
